import request from '@/utils/request'

//菜单列表
export function getAuthList(query) {
    return request({
        url: 'gui/auth/menuList',
        method: 'get',
        params: query
    })
}

//角色绑定菜单
export function roleBindMenu(data) {
    return request({
        url: 'gui/auth/roleBindMenu',
        method: 'post',
        data
    })
}

//管理员绑定角色
export function adminBindRole(data) {
    return request({
        url: 'gui/auth/adminBindRole',
        method: 'post',
        data
    })
}

//角色绑定管理员
export function roleBindAdmin(data) {
    return request({
        url: 'gui/auth/roleBindAdmin',
        method: 'post',
        data
    })
}


//查询角色绑定的用户
export function getRoleAdminList(query) {
    return request({
        url: 'gui/auth/roleAdmin',
        method: 'get',
        params: query
    })
}
//删除角色绑定用户
export function roleUnbindAdmin(data) {
    return request({
        url: 'gui/auth/roleUnbindAdmin',
        method: 'post',
        data
    })
}